# Contributor: Andy Hawkins <andy@gently.org.uk>
# Maintainer: Andy Hawkins <andy@gently.org.uk>
pkgname=py3-quantiphy
pkgver=2.17
pkgrel=0
pkgdesc="Physical Quantities"
url="https://quantiphy.readthedocs.io/"
arch="noarch"
license="MIT"
depends="
	python3
	"
makedepends="
	py3-setuptools
	"
checkdepends="
	py3-pytest
	py3-parametrize-from-file
	"
source="https://github.com/KenKundert/quantiphy/archive/v$pkgver/quantiphy-v$pkgver.tar.gz"
builddir="$srcdir/quantiphy-$pkgver"

build() {
	python3 setup.py build
}

check() {
	# Exclude manual tests as they create a circular dependency with py3-quantiphy_eval
	PYTHONPATH="$PWD/build/lib" pytest -k 'not test_manual'
}

package() {
	python3 setup.py install --prefix=/usr --root="$pkgdir"
}
sha512sums="
18e733e7b103071aa22c206435a658186dd9868a867c4b2fdfa1564b9c12cdea806c1a8fcee071b3ea4b1c8aa1dcfbd568517d09632f42687622657f1c63c926  quantiphy-v2.17.tar.gz
"
